package com.hbx.constant;

import lombok.Getter;
import lombok.Setter;

/*
 * @Author:hbx
 * 
 * */
public enum FeedbackEnum {
    DEVELOPER(1,"系统建议"),
    TECHNICAL_EXCHANGE(2,"技术交流"),
    BUG_REPORT(3,"BUG反馈"),

    ;
    @Getter
    @Setter
    private Integer id;

    @Getter
    @Setter
    private String type;

    FeedbackEnum(Integer id, String type){
        this.id = id;
        this.type = type;
    }

    public static String getType(Integer code){
        for (FeedbackEnum value : FeedbackEnum.values()) {
            if (value.getId().equals(code)){
                return value.getType();
            }
        }
        return null;
    }
}
